/*
* sso
*/
package com.opensso.domain.entity;

/**
 * 域名池 的实体类的状态
 * 状态：启用 Enable 禁用 Disable
 *
 * @author helixin
 */
public enum DomainPoolState implements java.io.Serializable {
    Enable("启用"),
    Disable("Disable"),;

    public String val;

    DomainPoolState(String val) {
        this.val = val;
    }

    /**
     * 根据状态名称查询状态
     *
     * @param stateName
     * @return
     */
    public static DomainPoolState getEnum(String stateName) {
        for (DomainPoolState domainPoolState : DomainPoolState.values()) {
            if (domainPoolState.name().equalsIgnoreCase(stateName)) {
                return domainPoolState;
            }
        }
        return null;
    }

    @Override
    public String toString() {
        return this.name();
    }

}
